(function() {
	var vm=new Vue({
		el:"#wrapper",
		data:{
			tab:true
		},
        mounted: function () {
            showHtml();
        },
		methods:{
			//tab切换
			tabSwitch:function(val){
				var loginTab=document.getElementById("loginTab"),
					registerTab=document.getElementById("registerTab"),
					login=document.getElementById("login"),
					register=document.getElementById("register");
				if(val==true){
					loginTab.setAttribute("class","navActive");
					registerTab.removeAttribute("class","navActive");
					login.style.display="block";
					register.style.display="none";
				}else if(val==false){
					loginTab.removeAttribute("class","navActive");
					registerTab.setAttribute("class","navActive");
					login.style.display="none";
					register.style.display="block";
				}
			},
			//密码是否显示明文
			pswExpress:function(psw,pswPic){
				var pswExpress=document.getElementById(pswPic),
					lPsw=document.getElementById(psw);
					console.log(lPsw)
				if(pswExpress.className=="noExpress"){
					lPsw.setAttribute("type","text");
					pswExpress.style.background="url(../image/icon/psw_icon2.png) no-repeat";
					pswExpress.setAttribute("class","yesExpress");
				}else if(pswExpress.className=="yesExpress"){
					lPsw.setAttribute("type","password");
					pswExpress.style.background="url(../image/icon/psw_icon1.png) no-repeat";
					pswExpress.setAttribute("class","noExpress");
				}
			},
			//注册成功填写信息
			registerIn:function(){
				var registerSuccess=document.getElementById("registerSuccess"),
					register=document.getElementById("register"),
					login=document.getElementById("login"),
					successTipBox=document.getElementById("successTipBox");
				registerSuccess.style.display="block";
				register.style.display="none";
				login.style.display="none";
				successTipBox.style.display="block";
			}
		}
	})
})(Vue)